package com.bdqn.service;

import com.bdqn.mapper.StorageRecordMapper;
import com.bdqn.pojo.StorageRecord;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service("storageRecordService")
public class StorageRecordServiceImpl implements StorageRecordService{
    // 注入mapper层
    @Resource
    private StorageRecordMapper storageRecordMapper;

    @Override
    public int getCount(){
        return storageRecordMapper.getCount();
    }
    @Override
    public List<StorageRecord> getStorageRecordList(int pageIndex, int pageSize, String queryGoodsName, Integer querySupplierId, Integer queryPayStatus) {
        return storageRecordMapper.getStorageRecordList(pageIndex,pageSize,queryGoodsName,querySupplierId,queryPayStatus);
    }

    @Override
    public int add(StorageRecord storageRecord) {
        return storageRecordMapper.add(storageRecord);
    }

    @Override
    public StorageRecord getStorageRecord(Integer storageRecordId) {
        return storageRecordMapper.getStorageRecord(storageRecordId);
    }

    @Override
    public int del(Integer storageRecordId) {
        return storageRecordMapper.del(storageRecordId);
    }


    @Override
    public int upd(StorageRecord storageRecord) {
        return storageRecordMapper.upd(storageRecord);
    }

}
